/**
 * App
 */

import React from 'react';
import './App.css';
import apiUrl from './ApiUrl';
const storage = window.localStorage;

class App extends React.Component {

    componentDidMount() {
        if (!storage.getItem('token')) {
            window.location.assign(apiUrl.merchant.login);
        } else {
            window.location.assign('#/dashboard');
        }
    }

    render() {
        return (
            <div className="container">
                <div className="alert alert-info" role="alert">loading, please wait!</div>
            </div>
        );
    }
}

export default App;